package net.csdn.business.common.domain.request;

import lombok.Data;
import net.csdn.business.common.enums.IssueEnum;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.Range;

import java.io.Serializable;

/**
 * @author likun
 * @date 2022/7/5 11:32
 */
@Data
public class IssueSearchQueryDto implements Serializable {
    private String uid;

    // @NotBlank(message = "keyword 不能为空")
    @Length(max = 50, message = "keyword 不能超过50个字符")
    private String keyword;

    @Range(min = 1, max = 2, message = "status 不合法")
    private Integer status;

    @Range(min = 1, max = 100, message = "pageNum 不合法")
    private int pageNum = 1;

    @Range(min = 1, max = 100, message = "pageSize 不合法")
    private int pageSize = 10;

    private String order = IssueEnum.OrderByEnum.RECENTLY_UPDATE.getCode();
}